<template>
  <div class="userInfo">
    <router-view />

    <van-tabbar route v-model="active">
      <van-tabbar-item :to="`/userInfo/detail/${userId}`" icon="home-o">
        个人信息
      </van-tabbar-item>
      <van-tabbar-item :to="`/userInfo/department/${userId}`" icon="cluster-o">
        部门信息
      </van-tabbar-item>
      <van-tabbar-item :to="`/userInfo/roleManage/${userId}`" icon="user-o">
        角色信息
      </van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script>
export default {
  name: "userInfo",
  data() {
    return {
      active: 0,
      userId: this.$route.params.id
    };
  }
};
</script>
